package com.ruoyi.item.domain;

import java.math.BigDecimal;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.core.annotation.Excel;
import com.ruoyi.common.core.web.domain.BaseEntity;

/**
 * 订单项表对象 order_item
 * 
 * @author ruoyi
 * @date 2025-10-10
 */
public class OrderItem extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 订单项ID */
    private Long id;

    /** 订单ID */
    @Excel(name = "订单ID")
    private Long orderId;

    /** 商品类型 */
    @Excel(name = "商品类型")
    private String entityType;

    /** 商品ID */
    @Excel(name = "商品ID")
    private Long entityId;

    /** 商品名称 */
    @Excel(name = "商品名称")
    private String itemName;

    /** 购买单价 */
    @Excel(name = "购买单价")
    private BigDecimal price;

    /** 数量 */
    @Excel(name = "数量")
    private Long quantity;

    public void setId(Long id) 
    {
        this.id = id;
    }

    public Long getId() 
    {
        return id;
    }

    public void setOrderId(Long orderId) 
    {
        this.orderId = orderId;
    }

    public Long getOrderId() 
    {
        return orderId;
    }

    public void setEntityType(String entityType) 
    {
        this.entityType = entityType;
    }

    public String getEntityType() 
    {
        return entityType;
    }

    public void setEntityId(Long entityId) 
    {
        this.entityId = entityId;
    }

    public Long getEntityId() 
    {
        return entityId;
    }

    public void setItemName(String itemName) 
    {
        this.itemName = itemName;
    }

    public String getItemName() 
    {
        return itemName;
    }

    public void setPrice(BigDecimal price) 
    {
        this.price = price;
    }

    public BigDecimal getPrice() 
    {
        return price;
    }

    public void setQuantity(Long quantity) 
    {
        this.quantity = quantity;
    }

    public Long getQuantity() 
    {
        return quantity;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("orderId", getOrderId())
            .append("entityType", getEntityType())
            .append("entityId", getEntityId())
            .append("itemName", getItemName())
            .append("price", getPrice())
            .append("quantity", getQuantity())
            .append("createTime", getCreateTime())
            .toString();
    }
}
